{% extends "BaseHeader.jinja" %}
{% block includes %}

#include "exi_basetypes.h"
#include "exi_bitstream.h"
{% endblock %}

{% block content %}
/**
 * \brief       Decode hexBinary
 *
 * \param       stream              EXI bitstream
 * \param       value_len           uint16_t (out) used length of decoded value
 * \param       value_buffer        byte buffer (out) decoded value
 * \param       value_buffer_size   size of the buffer
 * \return                          Error-Code <> 0, if no error 0
 *
 */
int decode_exi_type_hex_binary(exi_bitstream_t* stream, uint16_t* value_len, uint8_t* value_buffer, size_t value_buffer_size);

{% for size in [8, 16, 32, 64] -%}
/**
 * \brief       Decode {{ size }}-bit integer
 *
 * \param       stream              EXI bitstream
 * \param       value               int{{ size }}_t (out) decoded value
 * \return                          Error-Code <> 0, if no error 0
 *
 */
int decode_exi_type_integer{{ size }}(exi_bitstream_t* stream, int{{ size }}_t* value);

{% endfor -%}
{% for size in [8, 16, 32, 64] %}
/**
 * \brief       Decode {{ size }}-bit unsigned integer
 *
 * \param       stream              EXI bitstream
 * \param       value               uint{{ size }}_t (out) decoded value
 * \return                          Error-Code <> 0, if no error 0
 *
 */
int decode_exi_type_uint{{ size }}(exi_bitstream_t* stream, uint{{ size }}_t* value);
{% endfor -%}
{% endblock %}
